function resolved(result) {
  console.log('Resolved: ', result);
}

function rejected(error) {
  console.error(error);
}

// const p = Promise.reject(new Error('失败'));
const p = Promise.reject('失败');
console.log( p );

p.then(resolved, rejected);